<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Captcha extends CI_Controller{

	public function __construct(){
		parent::__construct();
		$this->load->library('session');
	}
	
	public function index(){
		header('Cache-Control: no-cache, must-revalidate');
		header('Pragma: no-cache');
		$this->load->library('caption');
		$code = $this->caption->rand_code();
		$this->session->set_userdata('capcode', $code);
		$this->caption->create();
	}
	
}
